#include<stdio.h>
int comb(int a,int b){
	int a_f=a/10;
	int a_e=a%10;
	int b_f=b/10;
	int b_e=b%10;
	int c=b_f+a_f*10+b_e*100+a_e*1000;
	return c;
}
int main(){
	int a,b;
	scanf("%d %d",&a,&b);
	int c=comb(a,b);
	printf("%d",c);
}
